<%@ page import="java.util.List" %>
<%@ page import="com.dailybule.java.bean.Emp" %>
<%@ page import="com.dailybule.java.service.EmpService" %>
<%@ page import="com.dailybule.java.service.impl.EmpServiceImpl" %>
<%@ page import="com.dailybule.java.bean.Emp" %>
<%@ page import="com.dailybule.java.service.impl.EmpServiceImpl" %><%--
  Created by IntelliJ IDEA.
  User: dailyblue
  Date: 2024/1/22
  Time: 14:45
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" isELIgnored="false" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>Title</title>

    <style>
        table {
            border: 1px gray solid;
            margin: auto;
            width: 80%;
            border-collapse: collapse;
        }

        th, td {
            border: 1px gray solid;
        }
    </style>
</head>
<body>
<%
    List<Emp> list = new EmpServiceImpl().find();
    session.setAttribute("LIST", list);
%>
<table>
    <tr>
        <th>序号</th>
        <th>姓名</th>
        <th>职位</th>
        <th>上司ID</th>
        <th>入职时间</th>
        <th>工资</th>
        <th>奖金</th>
        <th>部门ID</th>
    </tr>
    <c:forEach items="${LIST}" var="emp" varStatus="j">
        <tr>
            <td>${j.count}</td>
            <td>${emp.enname}</td>
            <td>${emp.job}</td>
            <td>${emp.mgr}</td>
            <td>${emp.hireDate}</td>
            <td>${emp.sal}</td>
            <td>${emp.comm}</td>
            <td>${emp.deptNo}</td>
        </tr>
    </c:forEach>
</table>
</body>
</html>